<?php

class Mem{
	private static $CONN = null; //连接资源

	public function __construct($host='127.0.0.1',$port='11211'){
		if(!class_exists('memcache')){
			throw new Exception("Service can not support memcache", 1);
		}
		$memcache = new memcache;
		if(!$memcache->connect($host,$port)){
			throw new Exception("Can not connect to the memcache service host", 1);
		}
	}
}

?>